package com.ruoyi.mall.ware.service;

import java.util.List;

import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.mall.ware.domain.Purchase;
import com.ruoyi.mall.ware.vo.MergeVo;
import com.ruoyi.mall.ware.vo.PurchaseDoneVo;

/**
 * 采购信息Service接口
 *
 * @author zhangqishu
 * @date 2022-06-14
 */
public interface IPurchaseService extends IService<Purchase>
{
    /**
     * 查询采购信息
     *
     * @param id 采购信息主键
     * @return 采购信息
     */
    public Purchase selectPurchaseById(Long id);

    /**
     * 查询采购信息列表
     *
     * @param purchase 采购信息
     * @return 采购信息集合
     */
    public List<Purchase> selectPurchaseList(Purchase purchase);

    /**
     * 新增采购信息
     *
     * @param purchase 采购信息
     * @return 结果
     */
    public int insertPurchase(Purchase purchase);

    /**
     * 修改采购信息
     *
     * @param purchase 采购信息
     * @return 结果
     */
    public int updatePurchase(Purchase purchase);

    /**
     * 批量删除采购信息
     *
     * @param ids 需要删除的采购信息主键集合
     * @return 结果
     */
    public int deletePurchaseByIds(Long[] ids);

    /**
     * 删除采购信息信息
     *
     * @param id 采购信息主键
     * @return 结果
     */
    public int deletePurchaseById(Long id);

    List<Purchase> unReceiveList(Purchase purchase);

    /**
     * 合并采购单
     * @param mergeVo
     * @return
     */
    int mergePurchase(MergeVo mergeVo);

    int receivedPurchase(List<Long> ids);

    /**
     * 完成采购单
     * @param purchaseDoneVo
     * @return
     */
    int donePurchase(PurchaseDoneVo purchaseDoneVo);
}
